<?php

namespace App\Providers;

use Illuminate\Support\ServiceProvider;
use Illuminate\Support\Facades\Schema;
use Blade;
class AppServiceProvider extends ServiceProvider
{
    /**
     * Register any application services.
     *
     * @return void
     */
    public function register()
    {
        //
    }

    /**
     * Bootstrap any application services.
     *
     * @return void
     */
    public function boot()
    {
        Schema::defaultStringLength(191);
        Blade::component('components.error', 'errmsg');
        Blade::component('dashboard.components.select', 'select');
        Blade::component('dashboard.components.input', 'text');
        Blade::component('dashboard.components.upload', 'upload');
        Blade::component('dashboard.components.radio', 'radio');
        Blade::component('dashboard.components.textarea', 'textarea');
        Blade::component('dashboard.components.submit', 'submit');
        Blade::component('dashboard.components.checkbox', 'checkbox');
        Blade::component('dashboard.components.checkbox-item', 'box');
        Blade::component('dashboard.components.attr', 'attr');
        Blade::component('dashboard.components.editor', 'editor');
        Blade::include('dashboard.components.input', 'input');
        Blade::include('dashboard.includes.category_select', 'category_select');
        Blade::include('dashboard.includes.brand_select', 'brand_select');
        
        //前台模板
        Blade::component('home.components.text-input', 'text');
    }
}
